package com.hexinfo.dmpro.monitor.dao;

import com.hexinfo.dmpro.monitor.model.MonitorClusResModel;
import com.hexinfo.dmpro.monitor.model.base.MonitorBaseModel;
import com.hexinfo.dmpro.monitor.model.base.MonitorReq;
import com.hexinfo.dmpro.monitor.model.cm.CmMessage;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

/**
 **/
@Repository
public interface MonitorDao {

    List<String> selAllEnabledCluster();
    List<Map<String,String>> selAllCluster(Map map);
    List<Map<String,String>> selAllUser(Map map);
    List<Map<String,String>> selAllUnit(Map map);
    List<Map<String,String>> selAllQueue(Map map);

    Map<String,Object> selTaskCount(MonitorReq req);
    List<Map<String,Object>> selTaskJobYarnCount(MonitorReq req);
    List<Map<String,Object>> selTaskJobYarnCountNow(MonitorReq req);
    List<Map<String,Object>> selTaskJobImaplaCount(MonitorReq req);
    List<Map<String,Object>> selTaskJobImaplaCountNow(MonitorReq req);
    List<Map<String,Object>> selTaskJobYarnTime(MonitorReq req);
    List<Map<String,Object>> selTaskJobYarnTimeNow(MonitorReq req);
    List<Map<String,Object>> selTaskJobImpalaTime(MonitorReq req);
    List<Map<String,Object>> selTaskJobImpalaTimeNow(MonitorReq req);

    Map<String, Object> selectPage();
    List<CmMessage> selectPageCm(CmMessage cmMessage);

    List<CmMessage> selectPageCmHdfs();

    List<Map<String,Object>> selTaskJobCountTime(MonitorReq req);

}
